//
//  XYPasswordView.h
//  xylink_app
//
//  Created by gao chenyang on 2020/4/24.
//  Copyright © 2020 ainemo. All rights reserved.
//

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN
@class XYPasswordView;

@protocol XYPasswordViewDelegate<NSObject>

-(void)passWordDidChange:(XYPasswordView *)password;

-(void)passWordCompleteInput:(XYPasswordView *)password;

-(void)passWordBeginInput:(XYPasswordView *)password;

@end

@interface XYPasswordView : UIView<UIKeyInput>

@property (nonatomic, assign) NSInteger passWordNum;//密码的位数
@property (nonatomic, assign) CGFloat squareWidth;//密码框的大小
@property (nonatomic, assign) CGFloat pointRadius;//黑点半径
@property (nonatomic, strong) UIColor *pointColor;//黑点颜色
@property (nonatomic, strong) UIColor *rectColor;//边框颜色
@property (nonatomic, weak) id<XYPasswordViewDelegate> delegate;
@property (nonatomic, readonly, strong) NSMutableString *textStore;//保存密码的字符串

@end

NS_ASSUME_NONNULL_END
